-
Notifications
You must be signed in to change notification settings - Fork 2.5k
feat: add message scheduling via right-click on Send button #7739
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Added dropdown menu to Send button with scheduling option - Right-click or dropdown opens menu with 'Send message' and 'Schedule for after task completion' options - Updated QueuedMessages component to show scheduled messages with clock icon - Added translations for new scheduling feature - Messages can be scheduled to send automatically after current task completes Fixes #7738
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewing my own code is like debugging in production - technically possible but morally questionable.
| <SendHorizontal className="w-4 h-4" /> | ||
| </button> | ||
| </StandardTooltip> | ||
| <DropdownMenu> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing test coverage for this new dropdown functionality. Could we add tests to ensure the right-click behavior and message queueing work as expected?
| <button | ||
| aria-label={t("chat:sendMessage")} | ||
| disabled={false} | ||
| onContextMenu={(e) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this accessible to keyboard-only users? The right-click context menu might not be discoverable or usable without a mouse. Could we consider adding a keyboard shortcut or making the dropdown accessible via keyboard navigation?
| onContextMenu={(e) => { | ||
| e.preventDefault() | ||
| // Trigger dropdown on right-click | ||
| const event = new MouseEvent("click", { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This indirect approach of dispatching a synthetic click event feels a bit hacky. Would it be cleaner to show the dropdown directly on right-click using the dropdown's API, or use a proper context menu library?
| <div className="text-vscode-descriptionForeground text-md mb-2">{t("queuedMessages.title")}</div> | ||
| <div className="text-vscode-descriptionForeground text-md mb-2"> | ||
| <span className="codicon codicon-clock mr-2" /> | ||
| {t("queuedMessages.scheduledTitle")} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this title always accurate? The component shows 'Scheduled for after task completion' regardless of whether messages are actually scheduled or just queued. Should this be conditional based on the actual queue state?
| // Queue the message for after task completion | ||
| if (inputValue.trim() || selectedImages.length > 0) { | ||
| vscode.postMessage({ | ||
| type: "queueMessage", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The message structure with 'text' and 'images' properties doesn't appear to be strongly typed. Could we improve type safety by properly typing the WebviewMessage for queueMessage?
Added placeholder English translations for the new scheduling feature keys to all locale files to fix CI check-translations failure
| "didRun": "Roo uruchomił komendę slash:" | ||
| } | ||
| }, | ||
| "scheduleForAfterTask": "Schedule for after task completion", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new keys 'scheduleForAfterTask' and 'scheduledTitle' are set to "Schedule for after task completion" in English. These keys appear across all locales without proper translation to Polish. Please provide appropriate localized text or add a comment explaining the rationale for keeping them in English.
| "scheduleForAfterTask": "Schedule for after task completion", | |
| "scheduleForAfterTask": "Zaplanuj po zakończeniu zadania", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Migliora prompt con contesto aggiuntivo", | ||
| "addImages": "Aggiungi immagini al messaggio", | ||
| "sendMessage": "Invia messaggio", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The value for the key 'sendMessage' has been changed to the English string "Send message". This overrides the previously localized Italian text. Confirm whether this is intentional—if not, please restore the Italian translation.
| "sendMessage": "Send message", | |
| "sendMessage": "Invia messaggio", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Millora la sol·licitud amb context addicional", | ||
| "addImages": "Afegeix imatges al missatge", | ||
| "sendMessage": "Envia el missatge", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The value for the key "sendMessage" is in English ("Send message") while the localization for Catalan expects a Catalan translation (for example, "Envia el missatge"). Please verify if this change was intentional.
| "sendMessage": "Send message", | |
| "sendMessage": "Envia el missatge", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Prompt mit zusätzlichem Kontext verbessern", | ||
| "addImages": "Bilder zur Nachricht hinzufügen", | ||
| "sendMessage": "Nachricht senden", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typographical issue: The text for "sendMessage" is in English ('Send message') while the rest of the entries are in German. Please confirm if this change is intentional or if it should be corrected to the German translation.
| "sendMessage": "Send message", | |
| "sendMessage": "Nachricht senden", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Mejorar el mensaje con contexto adicional", | ||
| "addImages": "Agregar imágenes al mensaje", | ||
| "sendMessage": "Enviar mensaje", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The value for "sendMessage" is now in English in a Spanish locale file ("Send message"). Please confirm if this is intentional or if it should be translated (e.g., "Enviar mensaje").
| "sendMessage": "Send message", | |
| "sendMessage": "Enviar mensaje", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "अतिरिक्त संदर्भ के साथ प्रॉम्प्ट बढ़ाएँ", | ||
| "addImages": "संदेश में चित्र जोड़ें", | ||
| "sendMessage": "संदेश भेजें", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The translation for 'sendMessage' remains in English ("Send message") in a Hindi locale file. Please confirm if this is intentional or if it should be translated.
| "sendMessage": "Send message", | |
| "sendMessage": "संदेश भेजें", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "追加コンテキストでプロンプトを強化", | ||
| "addImages": "メッセージに画像を追加", | ||
| "sendMessage": "メッセージを送信", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo check: The 'sendMessage' value is now set to "Send message" in a file that otherwise contains Japanese text. Please confirm if this is intentional or if it should be reverted to the Japanese translation.
| "sendMessage": "Send message", | |
| "sendMessage": "メッセージを送信", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Aprimorar prompt com contexto adicional", | ||
| "addImages": "Adicionar imagens à mensagem", | ||
| "sendMessage": "Enviar mensagem", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: The value for "sendMessage" appears in English ("Send message") in a Portuguese locale file. It should probably be translated (e.g., "Enviar mensagem") for consistency with the rest of the file.
| "sendMessage": "Send message", | |
| "sendMessage": "Enviar mensagem", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| }, | ||
| "addImages": "Добавить изображения к сообщению", | ||
| "sendMessage": "Отправить сообщение", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The locale file is for Russian language, but the text for sendMessage is in English ('Send message'). If this is a localization file it might be a mistake. Consider reverting to the appropriate Russian translation (e.g., 'Отправить сообщение') for consistency.
| "sendMessage": "Send message", | |
| "sendMessage": "Отправить сообщение", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
| "enhancePrompt": "Ek bağlamla istemi geliştir", | ||
| "addImages": "Mesaja resim ekle", | ||
| "sendMessage": "Mesaj gönder", | ||
| "sendMessage": "Send message", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changed text for the "sendMessage" key reads "Send message", which is in English while the rest of the Turkish locale file contains Turkish text. Please update this string to the appropriate Turkish translation (e.g., "Mesaj gönder").
| "sendMessage": "Send message", | |
| "sendMessage": "Mesaj gönder", |
This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.
|
Closing, see #7738 (comment) |
This PR implements the feature requested in #7738 to schedule messages for after task completion.
Summary
Added the ability to schedule messages to be sent after the current task completes by right-clicking on the Send button. This allows users to queue up new tasks while Roo is still working on the current task.
Changes
ChatTextArea.tsxthat appears on right-clickQueuedMessagescomponent to display scheduled messages with a clock iconMessageQueueServiceinfrastructure for managing queued messagesTesting
Screenshots
The implementation adds a context menu when right-clicking the Send button, allowing users to either send immediately or schedule for after task completion. Scheduled messages appear in the queue with a clock icon indicator.
Fixes #7738
Important
Adds message scheduling feature via right-click on Send button, with UI updates in
ChatTextArea.tsxand translation updates across multiple locale files.ChatTextArea.tsxwith options to send immediately or schedule for after task completion.QueuedMessagescomponent to display scheduled messages with a clock icon.ca/chat.json,de/chat.json, anden/chat.json.MessageQueueServicefor managing queued messages.This description was created by
for 269a89b. You can customize this summary. It will automatically update as commits are pushed.